#ifndef HOTEL_H
#define HOTEL_H

#include <string>

#include "rapidxml.hpp"

class Hotel{
public :
	static const std::string HOTEL_NODE;
	static const std::string HOTEL_NAME_NODE;
	static const std::string HOTEL_MAIL_NODE;

private :
	std::string* name;
	std::string* mail;

public :
	Hotel(void) : name(0), mail(0) {}
	
	Hotel(const Hotel& hotel){
		name = new std::string(*hotel.getName());
		mail = new std::string(*hotel.getMail());
	}

	Hotel(std::string _name, std::string _mail) {
		name = new std::string(_name);
		mail = new std::string(_mail);
	}

	virtual ~Hotel(void){
		delete(name);
		delete(mail);
	}

	std::string* getName(void) const { return name; }
	std::string* getMail(void) const { return mail; }

	void setName(std::string _name){
		if(name){
			delete(name);
		}

		name = new std::string(_name);
	}

	void setMail(std::string _mail){
		if(mail){
			delete(mail);
		}

		mail = new std::string(_mail);
	}

	rapidxml::xml_node<>* constructNode(rapidxml::xml_document<>* doc) const;
};

#endif //HOTEL_H